package one.stand.controller;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import one.stand.mapper.TrainCountMapper;
import one.stand.model.ResultModel;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Api(description = "培训统计管理")
@RestController
@RequestMapping("/trainCount")
@Slf4j
public class TrainCountController {
    @Autowired
    private TrainCountMapper trainCountMapper;

    @ApiOperation("统计+1")
    @PostMapping("/save")
    public ResultModel save() {
        trainCountMapper.countAdd();
        return ResultModel.success();
    }
}
